const mongoose = require("mongoose");
//数据库
const schema = new mongoose.Schema(
  {
    name: { type: String },
    name_en: { type: String },
    parent: { type: mongoose.SchemaTypes.ObjectId, ref: "Category" },
  },
  {
    timestamps: true,
  }
);

module.exports = mongoose.model("Category", schema);
